package com.storm.future.red.soviet;

import com.storm.future.red.common.AbstractBattleBase;
import com.storm.future.red.common.Building;
import com.storm.future.red.common.Defender;
import com.storm.future.red.soviet.solider.Boris;
import com.storm.future.red.soviet.solider.Conscript;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * @author gu
 * @date 2020/3/16 10:21
 */
@Component
public class SovietBattleBase extends AbstractBattleBase {

    private Boris boris ;
    private Conscript conscript ;


    @Autowired(required = false)
    public SovietBattleBase(Boris boris) {
        System.out.println("执行了单个参数的构造器");
        this.boris = boris;
    }
    @Autowired(required = false)
    public SovietBattleBase(Boris boris,Conscript conscript){
       this.conscript = conscript ;
       this.boris = boris ;
        System.out.println("执行了两个参数的构造器");
    }

    @Autowired(required = false)
    public SovietBattleBase(List<Boris> boris){
        this.boris = boris.get(0);
        System.out.println("执行了泛型构造器");
    }


    @Override
    public void construct(Building building) {

    }

    @Override
    public void construct(Defender defender) {

    }

    @Override
    public void increasePower(int power) {

    }
}
